import { createRouter, createWebHashHistory } from 'vue-router'

import AppView from './App.vue'

const routes = [
  {
    path: '/',
    component: AppView,
    children: [
      {
        path: '',
        name: 'HomePage',
        component: () => import('@/views/HomeView.vue')
      },
      {
        path: 'dialog',
        name: 'dialog',
        component: () => import('@/views/Dialog/Index.vue')
      },
      {
        path: 'svg',
        name: 'svg',
        component: () => import('@/views/SVG/Index.vue')
      },
      {
        path: 'imageView',
        name: 'image-view',
        component: () => import('@/views/ImageView/index.vue')
      },
      {
        path: 'message',
        name: 'message',
        component: () => import('@/views/Message/Index.vue')
      }
    ]
  }
]

const router = createRouter({
  history: createWebHashHistory(),
  routes
})

export default router
